<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  
  <title>OmegaT, the free translation memory tool</title>
  <meta name="generator" content="screem 0.10.2" />
  
  <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
  
  <meta name="keywords" content="translation memory, TM, computer-aided translation, computer-assisted translation, CAT, GPL, open source" />

  
<link rel="stylesheet" type="text/css" href="../../config/howto.css" />

</head>

<body>

<div id="container">
			
<div id="banner">

<h1>OmegaT</h1>

<p>The free (GPL) translation memory tool</p>

</div>

<div id="content">

<h2>OmegaT on Linux HowTo</h2>


<p>This HowTo provides information on using OmegaT on Linux. It is particularly aimed at users who are new to Linux.</p>

<h3>Java</h3>

<p>OmegaT does not run on all versions of Java. Before downloading OmegaT, first check the system's Java installation for its suitability for running OmegaT. To do this, open a terminal (also known as a console or command-line window; common programs for this are konsole (KDE) and gnome-terminal (GNOME), and type:</p>

<p>java -version</p>

<p>The system will output details of the Java version already installed at system level.</p>

<p>Sun Java versions: check the system requirements in the OmegaT documentation (readme.txt) for the precise Sun Java version required (i.e. whether your version of Java is sufficiently recent).</p>

<p>Third-party Java versions: until relatively recently, OmegaT only ran on Sun's own Java. OmegaT now appears to run on the OpenJDK Java implementation supplied with some Linux distributions, but some functions (such as the full set of command-line options) are not available; a different font set is supplied; and some glitches have been reported, such as with window display and the segmentation function.</p>

<p>If you are unsure whether your Java version is suitable, you can:</p>

<p>- Simply install an OmegaT version without Java and see whether it works. If it does not, you still have the option to install a local version of Java or a different version of Java at system level.</p>

<p>- Install a second, non-default version of Java at system level, and launch OmegaT explicitly using this version.</p>

<p>- Install the OmegaT version with Java included.</p>

<p>If you establish that the version of Java installed at system level is not compatible with OmegaT and you wish to replace this Java version with the Sun Java version, check first whether a Sun package is available for your Linux distribution (SUSE, Ubuntu, etc.). If so, this makes installation much easier.</p>

<p>If you obtain the Sun version of Java directly from Sun, installation is likely to be straightforward, but you will have to configure it manually in order to make it the default version at system level. This is not recommended, particularly if you are unfamiliar with Linux.</p>

<p>The third option, i.e. installing an OmegaT version with Java included at local level, is always the "failsafe" option.</p>

<h3>Selecting and downloading OmegaT</h3>

<p>The following versions of OmegaT are available for Linux:</p>

<p>"Standard", "Latest", "/trunk"  and "Webstart". The "Latest" version is recommended. (Refer to the "Downloads" page on the OmegaT website for details of the differences.)</p>

<p>Without/with JRE included, i.e. the cross-platform without JRE, e.g. "OmegaT_2.1.7_02_Beta_Without_JRE.zip" and the Linux-specific version with JRE, e.g. "OmegaT_2.1.7_02_Beta_Linux.tar.bz2". Select a version without or with JRE depending upon your Java situation (see above).</p>

<p>Note that it is easy to install multiple versions of OmegaT on Linux without conflicts. They will however always access the same user configuration files (unless launched from a different user account).</p>

<h3>Unpacking the archive</h3>

<p>Assuming that you have downloaded the latest beta version either with or without JRE, place it in a suitable folder on your system. I recommend creating an <i>/omegat</i> folder in /usr/local/lib, or failing that, in /opt. You will need root permissions to do this.</p>

<p>Unpack the archive in the desired folder. Most distributions should have no trouble unpacking the zip archive format or the .tar.bz2 format (the latter is a common archive format used on Linux).</p>

<p>Copying OmegaT onto your hard drive and unpacking the archive is sufficient to "install" it; there is no installation procedure as such. OmegaT creates certain user-specific folders and files when it is first run.</p>

<h3>Launching OmegaT from the command line</h3>

<p>First, try launching OmegaT from the command line. To do this, open a terminal window (see above). You do not need root permissions to do this. On the command line, navigate to the folder containing the file OmegaT.jar, e.g.:</p>

<p>cd /usr/local/lib/omegat/OmegaT_2.3.0</p>

<p>and confirm with ENTER. (The path will obviously be slightly different, depending upon where you have placed OmegaT and how you have named the folders.)</p>

<p>Then enter the launch command itself, and confirm with ENTER. The basic launch command is:</p>

<p>java -jar OmegaT.jar</p>

<p>The command is case-sensitive.</p>

<p>If you are relying on or wish to use a Java installation that is not installed at system level, this will not be sufficient: you must also instruct your system where to find Java. If you have installed a version of OmegaT with JRE supplied, the launch script supplied already contains this path for you. If you have installed an additional version of Java but have not made it the default version at system level, you must include the whole path of the Java binary in the launch command. This will be something like /usr/lib/jvm/java-6-sun-1.6.0.16/jre/bin/java; make a note of where Java is installed during installation so that you can find it again. The command will therefore be (in this case):</p>

<p>/usr/lib/jvm/java-6-sun-1.6.0.16/jre/bin/java -jar OmegaT.jar</p>

<p>In your launch script, do not confuse the path to OmegaT.jar and the path to the java command. The first (with the cd command) is needed if your launch script is not in the same folder as OmegaT.jar. The second is needed if the Java version you wish to use is not the default installation at system level.</p>

<h3>Launching OmegaT from a launch script</h3>

<p>Assuming that launching from the command line was successful, you can create a launch script. A basic launch script is supplied with OmegaT: it is the file named simply "OmegaT" in the main OmegaT folder. You can also create your own launch script(s): they are simply plain-text files and can be written/edited in a text editor.</p>

<p>The launch script must contain the commands described above, i.e.:</p>

<p>The basic OmegaT launch command, which is:</p>

<p>java -jar OmegaT.jar</p>

<p>Possibly with explicit reference to the location of the Java command, e.g. </p>

<p>/usr/lib/jvm/java-6-sun-1.6.0.16/jre/bin/java -jar OmegaT.jar</p>

<p>and possibly preceded by a command to change the folder to the folder containing the file OmegaT.jar, e.g.:</p>

<p>cd /usr/local/lib/omegat/OmegaT_2.3.0</p>

<p>Depending upon the Linux distribution you are using, the launch script may have to be made executable. To do this, right-click on the script file with the mouse, change "permissions" and check the "make executable" box. (The precise wording differs according to distribution.) Depending upon where the script is located, you may have to have root permissions to do this.</p>

<h3>Testing your launch script</h3>

<p>Open a terminal. Use the "cd" command to change folder to the location of your launch script, then type</p>

<p>./OmegaT</p>

<p>(assuming that your script file is named "OmegaT"), and confirm with ENTER. OmegaT should launch.</p>

<p>Depending upon your distribution, OmegaT may launch if you simply click on the launch script in your file manager.</p>

<h3>Making the launch script available throughout your system</h3>

<p>Copy or move the launch script file to a folder that is in the system's execution path; this is usually /usr/local/bin. If the file was previously in the same folder as OmegaT.jar, you will now need to precede the launch command with the "cd" command changing folder to location of OmegaT.jar.</p>

<p>To test whether OmegaT can be launched from anywhere on your system, open a terminal again and simply type the name of the script file, followed by ENTER. The file name is case-sensitive; if you wish to launch OmegaT simply by typing <i>omt</i>, simply rename the file from <i>OmegaT</i> to <i>omt</i>.</p>

<p>An even easier way of launching OmegaT is to hit Alt-F2, then to enter and confirm the name of the launch script in the dialog.</p>

<p>You can have multiple OmegaT launch scripts on your system. This enables you for example to try a new version of OmegaT whilst leaving the previous version completely unaffected: simply write a script for the new version and give it a different filename. Multiple launch scripts also enable you to launch OmegaT with different launch options where necessary, such as with a different tokenizer.</p>

<h3>User-friendly launching of OmegaT</h3>

<p>If you have got this far, you will have realized that there are many ways of launching OmegaT, and that they become progressively more user-friendly.</p>

<p>The next stage is to add OmegaT to your desktop and to menus. How you do this will depend upon your system, and in particular your desktop (e.g. KDE or GNOME). </p>

<p>Add an OmegaT menu entry in KDE as follows:</p>

<p>Control Center - Desktop - Panels - Menus - Edit K Menu - File - New Item/New Submenu</p>

<p>Then, after selecting a suitable menu, add a submenu/item with File - New Submenu and File - New Item. Enter OmegaT as the name of the new item.</p>

<p>In the "Command" field, use the navigation button to find your OmegaT launch script (the file named OmegaT in the unpacked folder), and select it.</p>

<p>Click on the icon button (to the right of the Name/Description/Comment fields) - Other Icons - Browse, and navigate to the /images subfolder in the OmegaT application folder. Select the OmegaT icon.</p>

<p>Finally, save the changes with File - Save.</p>

<p>In GNOME, add OmegaT to your panel (the bar at the top of the screen) as follows:</p>

<p>Right-click on the panel - Add New Launcher.</p>

<p>Enter "OmegaT" in the "Name" field; in the "Command" field, use the navigation button to find your OmegaT launch script (the file named OmegaT in the unpacked folder). Select it and confirm with OK.</p>

<p>Click on the icon button, then hit Browse... and navigate to the /images subfolder in the OmegaT application folder. Select the OmegaT_icon.png . GNOME may fail to display the icon files in the available formats and initially appear to expect an SVG file, but if the folder is selected, the files should appear and OmegaT_icon.png can be selected.</p>

<h3>Customizing your launch script</h3>

<p>OmegaT has a number of command-line options. You can use these, as their names suggests, on the command line, but you can also add them to your launch script. Refer to the OmegaT user manual for a full list of command-line options.</p>

<h3>Using Kaptain to launch OmegaT</h3>

<p>An alternative way of launching OmegaT on Linux is by using Kaptain. Kaptain enables a GUI to be created by which the launch options can be managed conveniently. This is particularly useful if you frequently use different versions of OmegaT or launch it with different arguments, such as different tokenizers.<br/>
<a href="../../resources/omegat.kaptn">An example Kaptain launch file</a><br/>
<a href="http://kaptain.sourceforge.net/">More information about Kaptain</a></p>


<h3>Appearance of fonts in OmegaT on Linux</h3>

<p>The appearance of fonts in OmegaT on Linux may differ widely, according to:</p>

<p>- The Java version used (the same font may appear quite different on Sun and OpenJDK versions of Java)</p>

<p>- The available/selected fonts</p>

<p>- The font size</p>

<p>- Whether anti-aliasing is enabled (this is a command-line launch option; refer to the OmegaT user manual for details) </p>

<h3>Uninstalling OmegaT</h3>

<p>To remove all traces of OmegaT from your system:</p>

<p>Delete the OmegaT program folder. This can easily be restored again in the future.</p>

<p>Delete the folder /home/&lt;user&gt;/.omegat of any user account from which OmegaT has been launched. This will result in deletion of any user configuration settings that have been made (such as changes to the segmentation rules), and – if the folder is deleted "properly", i.e. not simply moved to trash, cannot be restored.</p>

<p>Delete any launch scripts and remove any custom entries for OmegaT in your desktop.</p>

<p>Uninstalling OmegaT will not remove any OmegaT projects from your system, unless you have placed such projects within the OmegaT program or configuration files folder(s), which is not a good location for them in any case.</p>

<p>Copyright Marc Prior 2010-2011</p>

</div>

<div id="footer"><a href="http://sourceforge.net"><img src="http://sourceforge.net/sflogo.php?group_id=68187&amp;type=1" alt="SourceForge.net Logo" height="31" width="88" /></a><br />

<a href="http://validator.w3.org/check?uri=referer"><img src="../../images/xhtml.png" alt="Valid XHTML" /></a> <a href="http://jigsaw.w3.org/css-validator/check/referer"><img src="../../images/css.png" alt="Valid XHTML" /></a>
	</div>

</div>

</body></html>
